package edu.umd.ion.wavemeter.server;

import java.io.Serializable;
import java.util.Date;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.Id;
import javax.persistence.NamedQueries;
import javax.persistence.NamedQuery;
import javax.persistence.Table;

@SuppressWarnings("serial")
@Entity(name= "PIDCourseData")
@Table(name = "PIDCourseData")
@NamedQueries({
    @NamedQuery(name="all_pidcoursedata",
        query="SELECT x FROM PIDCourseData x")
})
public class PersistentPIDCourseData implements Serializable {
	@Id //signifies the primary key
	@Column(name = "Course", nullable = false, length=10000)
	protected String Course;
	protected Date LastUsed;
	protected long TimeUsed;
	
	public String getPrimaryKey() {
		return Course;
	}
	
	public void set(PersistentPIDCourseData o) {
		LastUsed = o.LastUsed;
		TimeUsed = o.TimeUsed;
	}
}
